package com.itheima.health.jobs;

import com.alibaba.dubbo.config.annotation.Reference;
import com.itheima.health.service.ClearOrderSettingService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
@Slf4j
public class ClearOrderSetting {
    /*
     * 定时清理预约设置的数据
     * */
    @Reference
    private ClearOrderSettingService clearOrderSettingService;

    public void clearOrderSettingjob() {
        System.out.println("执行了定时清理任务");
//        调用service清除方法
        clearOrderSettingService.deleteAll();
    }

}
